package ca.concordia.soen6461.wichf.navigation.action;

import java.util.Date;

import ca.concordia.soen6461.wichf.entity.ScheduledEvent.Type;
import ca.concordia.soen6461.wichf.entity.User;
import ca.concordia.soen6461.wichf.navigation.event.ManageAppointmentEvent;
import ca.concordia.soen6461.wichf.navigation.view.DoctorHomeView;
import ca.concordia.soen6461.wichf.navigation.view.DoctorHomeView.AvailabilityLimit;
import ca.concordia.soen6461.wichf.service.SchedulingService;

public class DoMakeAvailabilityFrom extends DoManageAppointment {

	public DoMakeAvailabilityFrom(SchedulingService schedulingService) {
		super(schedulingService);
	}
	
	protected void manageAppointment(SchedulingService schedulingService, ManageAppointmentEvent event, User user, Date from) {
		DoctorHomeView.AvailabilityLimit limit = new AvailabilityLimit(event.getDay(), event.getTime());
		event.getSession().keep(limit);
	}
	
	@Override
	protected Type getEventType() {
		return null;
	}

}
